package org.gdpi.ssh.server;

import java.util.List;

import org.gdpi.ssh.dao.GradeDao;
import org.gdpi.ssh.entitys.Grade;

public class GradeServer {
	
	private GradeDao gradeDao;
	public void setGradeDao(GradeDao gradeDao) {
		this.gradeDao = gradeDao;
	}

	public List<Grade> findAll(){
		return gradeDao.findAll();
	}
	
	public void add(Grade gra){
		gradeDao.add(gra);
	}
	
	public void update(Grade gra){
		gradeDao.update(gra);
	}
	
	public Grade get(Integer gradeId){
		return gradeDao.findById(gradeId);
	}
	
	public void delete(Grade grade){
		gradeDao.delete(grade);
	}
}
